package net.towee.client.widgets.upload.fileapi;

import com.google.gwt.core.client.JavaScriptObject;

public class File {
	private JavaScriptObject nativeFile;
	
	public File(JavaScriptObject file){
		this.nativeFile = file;
	}
	
	public JavaScriptObject asJsObject(){
		return nativeFile;
	}
	
	public native String getName() /*-{
		return this.@net.towee.client.widgets.upload.fileapi.File::nativeFile.name;
	}-*/;
	
	public native int getSize() /*-{
		return this.@net.towee.client.widgets.upload.fileapi.File::nativeFile.size;
	}-*/;
	
	public final native String getType() /*-{
		return this.@net.towee.client.widgets.upload.fileapi.File::nativeFile.type;
	}-*/;
}
